package Test;

import java.util.ArrayList;

import org.junit.Test;

import DBLayer.DBChild;
import ModelLayer.Child;

public class TestDBChild
{
	DBChild dbc = new DBChild();
	ArrayList<Child> clist = dbc.getAllChilds(false);

	@Test
	public void testGetAllChilds() {
	    System.out.println("\nNumbers of Child : " + clist.size() + "\n");
	}

	@Test
	public void testSearchChildID() {
		int id = 1;
		Child c = dbc.searchChildID(id, false);
		System.out.println("Child id           : " + c.getChildID());
		System.out.println("Person id          : " + c.getPersonID());
		System.out.println("Registreringd dato : " + c.getRegistrationDate());
		System.out.println("CPR                : " + c.getCPR());
		System.out.println("Navn               : " + c.getfName() + " " + c.getlName());
		System.out.println("Adresse            : " + c.getAddress());
		System.out.println("Postnr og By       : " + c.getPostalCode() + " " + c.getCity());
		System.out.println("Mobil              : " + c.getMobileNr());
		System.out.println("Telefon            : " + c.getPhoneNr());
		System.out.println("--------------------------------------------------");
	}
/*
	@Test
	public void testInsertChild() {
		fail("Not yet implemented");
	}

	@Test
	public void testUpdateChild() {
		fail("Not yet implemented");
	}

	@Test
	public void testDelete() {
		fail("Not yet implemented");
	}

	@Test
	public void testGetAllChild() {
		fail("Not yet implemented");
	}
*/
}
